package ai.gui;

import javax.swing.JFrame;

import ai.application.Config;

public class Gui {
	private JFrame f;
	private DrawArea drawArea;

	public DrawArea getDrawArea() {
		return drawArea;
	}

	public Gui(int minX, int minY, int maxX, int maxY) {
		this.f = new JFrame("Swing Paint Demo");
		this.f.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		this.drawArea = new DrawArea();
		this.f.add(drawArea);
		this.f.setSize(Config.WINDOW_SIZE_X+20,Config.WINDOW_SIZE_Y-80);
		this.f.setVisible(true);
		this.f.setResizable(false);
	}

	public void addDrawable(Drawable drawable) {
		this.drawArea.getDrawables().add(drawable);
	}
}
